package vendalenger.debvi.jfx;

import java.awt.BorderLayout;
import java.awt.Graphics;
import java.util.ArrayList;

import javax.swing.BorderFactory;
import javax.swing.DefaultComboBoxModel;
import javax.swing.JComboBox;
import javax.swing.JPanel;
import javax.swing.JSplitPane;

public class VD_DADCodeEditor extends JPanel {
	
	private static final long serialVersionUID = 1L;
	public JComboBox<Object> category;
	public JPanel board;
	public JPanel components;
	
	public VD_DADCodeEditor() {
		super();
		setLayout(new BorderLayout());
		setBorder(BorderFactory.createEtchedBorder());
		board = new JPanel();
		category = new JComboBox<Object>();
		components = new JPanel();
		components.setBorder(BorderFactory.createLoweredBevelBorder());
		ArrayList<Category> cats = new ArrayList<Category>();
		cats.add(new Category());
		category.setModel(new DefaultComboBoxModel<Object>(cats.toArray()));
		board.setLayout(new BorderLayout());
		JPanel components_ag = new JPanel();
		components_ag.setLayout(new BorderLayout());
		components_ag.add(category, BorderLayout.NORTH);
		components_ag.add(components, BorderLayout.CENTER);
		add(new JSplitPane(JSplitPane.HORIZONTAL_SPLIT, components_ag, board));
	}
	
	@Override
	protected void paintComponent(Graphics g) {
		super.paintComponent(g);
		
	}
}

class Category {
	
	String name;
	
	@Override
	public String toString() {
		name = "eggs";
		return name;
	}
	
}